<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box {
            width: 800px;
            height: 100px;
            display: grid;
            /* 关键代码 意思是将容器分为三列，左边一列为100px，右边一列为100px，中间列占满剩余的宽度*/
            grid-template-columns: 100px auto 100px;
        }

        .box .left {
            background: red;
        }

        .box .right {
            background: blue;
        }


        .box .center {
            background: green;
        }
    </style>
</head>

<body>
    <div class="box">
        <div class="left">left</div>
        <div class="center">center</div>
        <div class="right">right</div>
    </div>
</body>

</html>